//
//  LaBaView.m
//  yigou
//
//  Created by SunChao on 17/2/8.
//  Copyright © 2017年 hanyiwang. All rights reserved.
//

#import "LaBaView.h"

@implementation LaBaView

-(instancetype)initWithFrame:(CGRect)frame
{
    
    self = [super initWithFrame:frame];
    if (self) {
        
        _dataSource = [NSMutableArray array];
        
        [self initView];
    }
    return self;
}
- (void)initView{
    
    if (_imgView == nil) {
        _imgView = [[UIImageView alloc]initWithFrame:CGRectMake(0, 5, 20, 20)];
         _imgView.image = [UIImage imageNamed:@"喇叭"];
        [self addSubview:_imgView];
        
    }
    
    
    if (_label ==nil) {
        _label = [[UILabel alloc]initWithFrame:CGRectMake(40, 5, 40, 20)];
        _label.layer.cornerRadius = 5;
        _label.layer.masksToBounds = YES;
        _label.backgroundColor = QINGColor;
        _label.textAlignment = NSTextAlignmentCenter;
        [self addSubview:_label];
        _label.font = [UIFont systemFontOfSize:13];

    }
    
    if (_detailLabel == nil) {
        _detailLabel = [[UILabel alloc]initWithFrame:CGRectMake(85, 0, SCREEN_WIDTH-85, 30)];
        _detailLabel.textAlignment = NSTextAlignmentLeft;
        [self addSubview:_detailLabel];

    }
}
@end
